﻿<?xml version="1.0" encoding="utf-8" ?>

<program_def>
	<code_block>
		<class_def name="HelloClass">
			<code_block>
				
				<function_def name="init">
					<parameters>
						<param>
							<variable name ="arg1"/>
						</param>
						<param>
							<variable name ="arg2"/>
						</param>
					</parameters>
					<code_block>
						<assignment>
							<left>
								<instance_variable name ="arg1" />
							</left>
							<right>
								<variable name ="arg1"/>
							</right>
						</assignment>
						<assignment>
							<left>
								<instance_variable name ="arg2" />
							</left>
							<right>
								<variable name ="arg2"/>
							</right>
						</assignment>
					</code_block>
					
				</function_def>
				<function_def name="show">
					<code_block>
						<return>
							<binary operator ="+">
								<left>
									<instance_variable name ="arg1" />
								</left>
								<right>
									<instance_variable name ="arg2" />
								</right>
							</binary>
						</return>
					</code_block>
				</function_def>
				
			</code_block>
		</class_def>

		<assignment>
			<left>
				<variable name ="obj" />
			</left>
			<right>
				<function_call method="create">
					<calling_object>
						<class_reference name="HelloClass" />
					</calling_object>
					<arguments>
						<constant value="'Hello, '" />
						<constant value="'World!'" />
					</arguments>
				</function_call>
			</right>
		</assignment>
		<function_call method="print">
			<arguments>
				<function_call method="show">
					<calling_object>
						<variable name="obj" />
					</calling_object>
				</function_call>
			</arguments>
		</function_call>
	</code_block>
</program_def>
